package cn.java.Concurrency;

import java.util.concurrent.Callable;

/**
 * @author 小石潭记
 * @date 2021/12/19 11:18
 * @Description: ${todo}
 */
public class MyCallable1 implements Callable<String> {
    @Override
    public String call() throws Exception {
        int i = 0;
        while (i == 0) {
            if (Thread.currentThread().isInterrupted()) {
                throw new InterruptedException();
            }
            System.out.println("正则运行中...");
        }
        return "我的年龄 100";
    }
}
